#! python3
# - Reads Word documents.
import os
import docx

def getDocxText(filename):
    doc = docx.Document(filename)
    fullText = []
    for para in doc.paragraphs:
        fullText.append(para.text)
    return '\n\n'.join(fullText)

# Get Current Working Directory
current_dir = os.getcwd()

# Splicing paths together to get the full path to the file
docx_file_path = os.path.join(current_dir, 'materials', 'word', 'demo.docx')
print(docx_file_path)

print(getDocxText(docx_file_path))